<?php
/*
 * [JINYUN!] (C)2001-2099 Jinyunweb.com
 * This is NOT a freeware, use is subject to license terms
 * $Id: 2017-12-13 03:39:35 apple $
*/
defined('BY_JYA') or exit('error');
cfc('core')->checklogin();
$_RQ['op']=$_RQ['op']?$_RQ['op']:'get';
if($_RQ['op']=='get'){
	$return=array();
	$item=pdo_get('jy_vote_user',array('mid'=>$_SESSION['uid'],'uniacid'=>$_SESSION['uniacid']),array('nickname','avatar'));
	$return['item'] =$item;
	exi($return);
}
if($_RQ['op']=='getwechat'){
	exi('获取成功！');
}
if($_RQ['op']=='post'){
	$data=get_postdata();
	$data=array_fields(array('nickname','avatar'),$data);
	pdo_update('jy_vote_user',$data,array('mid'=>$_SESSION['uid'],'uniacid'=>$_SESSION['uniacid']));
	exi('设置成功！','','goback');
}